package com.lemon.blog.system.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.lemon.common.core.annotation.Excel;
import com.lemon.common.core.serializer.JsonLongDeserializer;
import com.lemon.common.core.serializer.JsonLongSerializer;
import com.lemon.common.core.base.BaseEntity;

/**
 * 包名称：com.lemon.blog.system.domain
 * 类名称：BlBlogViewRecord
 * 类描述：文章浏览记录对象 bl_blog_view_record
 * 创建人：@author lemon
 * 创建时间：2024-01-20
 */
public class BlBlogViewRecord extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 主键 */
    @JsonSerialize(using = JsonLongSerializer.class)
    @JsonDeserialize(using = JsonLongDeserializer.class)
    private Long id;

    /** 文章id */
    @Excel(name = "文章id")
    @JsonSerialize(using = JsonLongSerializer.class)
    @JsonDeserialize(using = JsonLongDeserializer.class)
    private Long blogId;

    /** 用户id */
    @Excel(name = "用户id")
    @JsonSerialize(using = JsonLongSerializer.class)
    @JsonDeserialize(using = JsonLongDeserializer.class)
    private Long userId;

    /** ip地址 */
    @Excel(name = "ip地址")
    private String ipAddress;

    /** 浏览器信息 */
    @Excel(name = "浏览器信息")
    private String browserInfo;

    /** 操作系统信息 */
    @Excel(name = "操作系统信息")
    private String osInfo;

    /** 是否删除，0否1是 */
    private String delFlag;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }
    public void setBlogId(Long blogId) {
        this.blogId = blogId;
    }

    public Long getBlogId() {
        return blogId;
    }
    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Long getUserId() {
        return userId;
    }
    public void setIpAddress(String ipAddress) {
        this.ipAddress = ipAddress;
    }

    public String getIpAddress() {
        return ipAddress;
    }
    public void setBrowserInfo(String browserInfo) {
        this.browserInfo = browserInfo;
    }

    public String getBrowserInfo() {
        return browserInfo;
    }
    public void setOsInfo(String osInfo) {
        this.osInfo = osInfo;
    }

    public String getOsInfo() {
        return osInfo;
    }
    public void setDelFlag(String delFlag) {
        this.delFlag = delFlag;
    }

    public String getDelFlag() {
        return delFlag;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("blogId", getBlogId())
            .append("userId", getUserId())
            .append("ipAddress", getIpAddress())
            .append("browserInfo", getBrowserInfo())
            .append("osInfo", getOsInfo())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("createBy", getCreateBy())
            .append("updateBy", getUpdateBy())
            .append("remark", getRemark())
            .append("delFlag", getDelFlag())
            .toString();
    }
}
